package br.mil.eb.decex.ati.util;

import br.mil.eb.decex.ati.material.MaterialDAO;
import br.mil.eb.decex.ati.material.MaterialDAOHibernate;
import br.mil.eb.decex.ati.ordemservico.OrdemServicoDAO;
import br.mil.eb.decex.ati.ordemservico.OrdemServicoDAOHibernate;
import br.mil.eb.decex.ati.usuario.UsuarioDAO;
import br.mil.eb.decex.ati.usuario.UsuarioDAOHibernate;

public class DAOFactory {

	public static UsuarioDAO criaUsuarioDAO() {
		UsuarioDAOHibernate usuarioDAOHibernate = new UsuarioDAOHibernate();		
		usuarioDAOHibernate.setSessao(HibernateUtil.getSession().getCurrentSession());
		
		return usuarioDAOHibernate;
	}

	public static MaterialDAO criaMaterialDAO() {
		MaterialDAOHibernate materialDAOHibernate = new MaterialDAOHibernate();		
		materialDAOHibernate.setSessao(HibernateUtil.getSession().getCurrentSession());
		return materialDAOHibernate;
	}

	public static OrdemServicoDAO criaOrdemServicoDAO() {
		OrdemServicoDAOHibernate ordemServicoDAOHibernate = new OrdemServicoDAOHibernate();
		ordemServicoDAOHibernate.setSessao(HibernateUtil.getSession().getCurrentSession());
		return ordemServicoDAOHibernate;
	}
	

}
